package _struct

import "fmt"

type cloth struct {
	color string
	size  int
}

type Person struct {
	name  string
	age   int
	color string
	cloth struct {
		color string
		size  int
	}
	cloth2 cloth
}

type A struct {
	B
	name string
}

type B struct {
	age int
}

func Print() {
	person := Person{
		name:  "wwy",
		age:   11,
		color: "red",
		cloth: struct {
			color string
			size  int
		}{color: "blank", size: 3},
		cloth2: cloth{
			color: "green",
			size:  233,
		},
	}
	person.cloth.color = "blue"
	fmt.Println(person)
}

func Print2() {
	a := A{name: "wwy", B: B{
		age: 13,
	}}
	//a.age = 12
	fmt.Println(a)
}
